﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using BusinessLayer;

namespace PresentationLayer
{
    public partial class CriarVeiculo : Form
    {
        public CriarVeiculo()
        {
            InitializeComponent();
        }

        private void Criar_Click(object sender, EventArgs e)
        {
            this.textMatricula.SelectAll();
            this.textMarca.SelectAll();
            this.textModelo.SelectAll();
            this.textNome.SelectAll();

            if (VeiculoActions.CriarVeiculo(this.textMatricula.SelectedText, this.textMarca.SelectedText, this.textModelo.SelectedText, this.textNome.SelectedText))
                this.Close();
            else MessageBox.Show("Verifique os dados");
        }
    }
}
